/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package edu.wpi.first.wpilibj.templates.commands;


/**
 *
 * @author Conor
 */
public class SetFan extends CommandBase {
private double setpoint;
    public SetFan(double setpoint) {
    requires(fanpid);
    this.setpoint = setpoint;
    }
    protected void initialize() {
        fanpid.setSetpoint(setpoint);
    }

    protected void execute() {        
    }

    protected boolean isFinished() {
        return Math.abs(fanpid.getPosition() - setpoint) < 25;
    }

    protected void end() {
    }

    protected void interrupted() {
    }    
}
